package net.bw.realtime.jtp.mapper;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * @Author: lianyuez
 * @Date: 2025/6/5
 */



@Mapper
public interface TotalAmountCntMapper {

//	-- 总下单量下单金额
	@Select("SELECT\n" +
			"     sum(split_total_amount) AS order_amount\n" +
			"FROM jtp_mall_doris.dwd_order_detail")
	Double  selectTotalAmountCnt(@Param("date")String date) ;

//	-- 总下单量订单数
	@Select("SELECT\n" +
			"    count(order_id) / 12 AS order_count\n" +
			"FROM jtp_mall_doris.dwd_order_detail")
	Double   selectTotalOrderCnt(@Param("date")String date) ;

}
